#ifndef AUX_DEBUGMSG_H
#define AUX_DEBUGMSG_H
#ifdef __cplusplus
extern "C" {
#endif
#include "aux_types.h"
#include "aux_errno.h"
EErrNo aux_prt_debug(const char *pStrFmt,...);

EErrNo aux_prt_err(const char *pStrFmt,...);
EErrNo aux_prt_warn(const char *pStrFmt,...);
EErrNo aux_prt_debug_array(u8 *pbyData, u32 nCnt);

/* VC6.0 not support variant number of parameters, so use the following */
#define AUX_DEBUG_STR(X) aux_prt_debug(__FUNCTION_NAME__ ": " X)
#define AUX_ERR_STR(X) aux_prt_err(__FUNCTION_NAME__ ": " X)

#define AUX_DEBUG_STR_SZPONTER(PREVSTR, X) \
    aux_prt_debug(__FUNCTION_NAME__ " " PREVSTR " %s", X)

#define AUX_DEBUG_STR_INT(PREVSTR, X) \
    aux_prt_debug(__FUNCTION_NAME__ " " PREVSTR " %d", X)
#define AUX_DEBUG_STR_INT_ENDL(PREVSTR, X) \
    aux_prt_debug(__FUNCTION_NAME__ " " PREVSTR " %d\n", X)
#define AUX_DEBUG_STR_UINT_ENDL(PREVSTR, X) \
    aux_prt_debug(__FUNCTION_NAME__ " " PREVSTR " %u\n", X)
#define AUX_DEBUG_RAW_STR(X) aux_prt_debug(X)
#ifdef __cplusplus
}
#endif
#endif
